package org.star.controller;

import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.star.feign.StockFeignService12000;

import javax.annotation.Resource;

/**
 * @Author : 一叶浮萍归大海
 * @Date: 2024/6/11 17:55
 * @Description:
 */
@Slf4j
@RequestMapping("/order")
@RestController
public class OrderController12000 {

    @Resource
    private StockFeignService12000 stockFeignService;

    @GetMapping("/placingOrder")
    public String placingOrder() {
        log.info("下单成功!");

        String result = stockFeignService.reduceStock();
        log.info("result:{}", result);

        return "下单成功********O(∩_∩)O";
    }

}
